Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add file:// method #512

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Conversation

step-
Copy link

@step- step- commented Sep 18, 2023

Issue #508 reports that href file://... is mapped to http://remote.../file://..., which will never open in modern browsers capable of opening the "file://" method.

This is a proposed fix for #508.

The screenshot illustrates the use case. After converting an online HTML document to PDF (using the command shown in #507), open the output file in a PDF viewer, scroll down to the link in the screenshot, and click the link. Without this commit the PDF viewer, then the browser, open http://remote.../file://..., and fail. With this commit the "file://" method is preserved, so the browser can successfully open a local file.

screenshot

Issue michaelrsweet#508 reports that
href "file://..." is mapped to "http://remote.../file://...", which will
never open in modern browsers capable of opening the "file://" method.

This is a proposed fix for michaelrsweet#508.

The screenshot illustrates the use case. After converting an online HTML
document to PDF (using the command shown in michaelrsweet#507), open the output file
in a PDF viewer, scroll down to the link in the screenshot, and click
the link. Without this commit the PDF viewer, then the browser, open
"http://remote.../file://...", and fail. With this commit the "file://"
method is preserved, so the browser can successfully open a local file.

![screenshot](https://github.com/michaelrsweet/htmldoc/assets/1414102/814f30a0-f417-46eb-8390-a94542162050)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant